home *** CD-ROM | disk | FTP | other *** search
/ NeXT Education Software Sampler 1992 Fall / NeXT Education Software Sampler 1992 Fall.iso / Programming / Classes / CryptSums / Makefile < prev    next >
Encoding:
Makefile  |  1992-05-18  |  794 b   |  29 lines

  1. PASSWORD = sd4u53ut
  2.  
  3. SEGMENT = __CRYPTSUM
  4. SECTION = __table
  5.  
  6. CFLAGS = -g -Wall -O
  7.  
  8. LIBS = -L. -lcryptsum 
  9. LDFLAGS = -segcreate ${SEGMENT} ${SECTION} dummy.cryptsums
  10.  
  11. all: libcryptsum.a cryptsums example
  12.  
  13. libcryptsum.a: cryptsum.c cryptsum.h
  14.     ${CC} ${CFLAGS} -c cryptsum.c
  15.     ar crv libcryptsum.a cryptsum.o
  16.     ranlib libcryptsum.a
  17.     
  18. cryptsums: libcryptsum.a cryptsums.c
  19.     ${CC} -o cryptsums ${CFLAGS} cryptsums.c ${LIBS}
  20.     
  21. example: libcryptsum.a cryptsums example.c
  22.     ${CC} -o example.unsecure ${CFLAGS} -DSECURE -DPASSWORD=\"${PASSWORD}\" example.c ${LIBS} ${LDFLAGS}
  23.     cryptsums example.unsecure ${PASSWORD} > example.cryptsums
  24.     segedit example.unsecure -replace ${SEGMENT} ${SECTION} example.cryptsums -output example.secure
  25.     
  26. clean:
  27.     rm -f *.a *.o *.unsecure *.secure cryptsums example.cryptsums
  28.  
  29.